/**
 * <copyright>
 * </copyright>
 *
 * $Id$
 */
package ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.util;

import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.And;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.BusinessMessage;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.CFSNoSync;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.CFSSync;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Cancel;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Compensation;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Condition;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.ControlFlowSegment;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Correlation;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.If;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.InteractionPath;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.InteractionProtocol;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.InteractionProtocolElement;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.InteractionprotocolsPackage;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Lifeline;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Loop;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.LoopType;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.MultipleInstance;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.MultipleInstancesType;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Or;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.ProtocolReference;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Role;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.SynchronizationType;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Termination;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.TerminationElement;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.TimeConstraint;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.TimeExpresion;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.TimeObservation;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Transaction;
import ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Xor;

import java.util.Map;

import org.eclipse.emf.common.util.DiagnosticChain;
import org.eclipse.emf.common.util.ResourceLocator;

import org.eclipse.emf.ecore.EPackage;

import org.eclipse.emf.ecore.util.EObjectValidator;

/**
 * <!-- begin-user-doc -->
 * The <b>Validator</b> for the model.
 * <!-- end-user-doc -->
 * @see ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.InteractionprotocolsPackage
 * @generated
 */
public class InteractionprotocolsValidator extends EObjectValidator {
	/**
	 * The cached model package
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final InteractionprotocolsValidator INSTANCE = new InteractionprotocolsValidator();

	/**
	 * A constant for the {@link org.eclipse.emf.common.util.Diagnostic#getSource() source} of diagnostic {@link org.eclipse.emf.common.util.Diagnostic#getCode() codes} from this package.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see org.eclipse.emf.common.util.Diagnostic#getSource()
	 * @see org.eclipse.emf.common.util.Diagnostic#getCode()
	 * @generated
	 */
	public static final String DIAGNOSTIC_SOURCE = "ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols"; //$NON-NLS-1$

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Termination Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__TERMINATION_VERIFICATION = 1;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Or Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__OR_VERIFICATION = 2;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Cancel Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__CANCEL_VERIFICATION = 3;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Exception Termination Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__EXCEPTION_TERMINATION_VERIFICATION = 4;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Termination First Level Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__TERMINATION_FIRST_LEVEL_VERIFICATION = 5;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'While Termination Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__WHILE_TERMINATION_VERIFICATION = 6;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Until Termination Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__UNTIL_TERMINATION_VERIFICATION = 7;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Multiple Instance Termination Verification' of 'Termination'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int TERMINATION__MULTIPLE_INSTANCE_TERMINATION_VERIFICATION = 8;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Interaction Path Terminations' of 'Xor'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int XOR__INTERACTION_PATH_TERMINATIONS = 9;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Cancel And Verification' of 'Cancel'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int CANCEL__CANCEL_AND_VERIFICATION = 10;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Cancel Or Verification' of 'Cancel'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int CANCEL__CANCEL_OR_VERIFICATION = 11;

	/**
	 * The {@link org.eclipse.emf.common.util.Diagnostic#getCode() code} for constraint 'Cancel Or Verification' of 'Cancel'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final int EMPTY_INTERACTION_PATH = 12;

	/**
	 * A constant with a fixed name that can be used as the base value for additional hand written constants.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private static final int GENERATED_DIAGNOSTIC_CODE_COUNT = 11;

	/**
	 * A constant with a fixed name that can be used as the base value for additional hand written constants in a derived class.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	protected static final int DIAGNOSTIC_CODE_COUNT = GENERATED_DIAGNOSTIC_CODE_COUNT;

	/**
	 * Creates an instance of the switch.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public InteractionprotocolsValidator() {
		super();
	}

	/**
	 * Returns the package of this validator switch.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	protected EPackage getEPackage() {
	  return InteractionprotocolsPackage.eINSTANCE;
	}

	/**
	 * Calls <code>validateXXX</code> for the corresponding classifier of the model.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated NOT
	 */
	@Override
	protected boolean validate(int classifierID, Object value, DiagnosticChain diagnostics, Map<Object, Object> context) {
		switch (classifierID) {
//			case InteractionprotocolsPackage.BUSINESS_MESSAGE:
//				return validateBusinessMessage((BusinessMessage)value, diagnostics, context);
//			case InteractionprotocolsPackage.INTERACTION_PROTOCOL_ELEMENT:
//				return validateInteractionProtocolElement((InteractionProtocolElement)value, diagnostics, context);
//			case InteractionprotocolsPackage.INTERACTION_PROTOCOL:
//				return validateInteractionProtocol((InteractionProtocol)value, diagnostics, context);
//			case InteractionprotocolsPackage.CONTROL_FLOW_SEGMENT:
//				return validateControlFlowSegment((ControlFlowSegment)value, diagnostics, context);
			case InteractionprotocolsPackage.INTERACTION_PATH:
				return validateInteractionPath((InteractionPath)value, diagnostics, context);
//			case InteractionprotocolsPackage.LIFELINE:
//				return validateLifeline((Lifeline)value, diagnostics, context);
			case InteractionprotocolsPackage.TERMINATION:
				return validateTermination((Termination)value, diagnostics, context);
//			case InteractionprotocolsPackage.CONDITION:
//				return validateCondition((Condition)value, diagnostics, context);
//			case InteractionprotocolsPackage.TIME_EXPRESION:
//				return validateTimeExpresion((TimeExpresion)value, diagnostics, context);
//			case InteractionprotocolsPackage.TIME_CONSTRAINT:
//				return validateTimeConstraint((TimeConstraint)value, diagnostics, context);
//			case InteractionprotocolsPackage.TIME_OBSERVATION:
//				return validateTimeObservation((TimeObservation)value, diagnostics, context);
//			case InteractionprotocolsPackage.PROTOCOL_REFERENCE:
//				return validateProtocolReference((ProtocolReference)value, diagnostics, context);
//			case InteractionprotocolsPackage.CORRELATION:
//				return validateCorrelation((Correlation)value, diagnostics, context);
//			case InteractionprotocolsPackage.ROLE:
//				return validateRole((Role)value, diagnostics, context);
//			case InteractionprotocolsPackage.CFS_SYNC:
//				return validateCFSSync((CFSSync)value, diagnostics, context);
//			case InteractionprotocolsPackage.CFS_NO_SYNC:
//				return validateCFSNoSync((CFSNoSync)value, diagnostics, context);
//			case InteractionprotocolsPackage.AND:
//				return validateAnd((And)value, diagnostics, context);
//			case InteractionprotocolsPackage.OR:
//				return validateOr((Or)value, diagnostics, context);
			case InteractionprotocolsPackage.XOR:
				return validateXor((Xor)value, diagnostics, context);
//			case InteractionprotocolsPackage.IF:
//				return validateIf((If)value, diagnostics, context);
//			case InteractionprotocolsPackage.LOOP:
//				return validateLoop((Loop)value, diagnostics, context);
//			case InteractionprotocolsPackage.EXCEPTION:
//				return validateException((ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Exception)value, diagnostics, context);
			case InteractionprotocolsPackage.CANCEL:
				return validateCancel((Cancel)value, diagnostics, context);
//			case InteractionprotocolsPackage.MULTIPLE_INSTANCE:
//				return validateMultipleInstance((MultipleInstance)value, diagnostics, context);
//			case InteractionprotocolsPackage.TRANSACTION:
//				return validateTransaction((Transaction)value, diagnostics, context);
//			case InteractionprotocolsPackage.COMPENSATION:
//				return validateCompensation((Compensation)value, diagnostics, context);
			case InteractionprotocolsPackage.TERMINATION_ELEMENT:
				return validateTerminationElement((TerminationElement)value, diagnostics, context);
			case InteractionprotocolsPackage.LOOP_TYPE:
				return validateLoopType((LoopType)value, diagnostics, context);
			case InteractionprotocolsPackage.MULTIPLE_INSTANCES_TYPE:
				return validateMultipleInstancesType((MultipleInstancesType)value, diagnostics, context);
			case InteractionprotocolsPackage.SYNCHRONIZATION_TYPE:
				return validateSynchronizationType((SynchronizationType)value, diagnostics, context);
			default:
				return true;
		}
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateBusinessMessage(BusinessMessage businessMessage, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(businessMessage, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateInteractionProtocolElement(InteractionProtocolElement interactionProtocolElement, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(interactionProtocolElement, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateInteractionProtocol(InteractionProtocol interactionProtocol, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(interactionProtocol, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateControlFlowSegment(ControlFlowSegment controlFlowSegment, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(controlFlowSegment, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated NOT
	 */
	public boolean validateInteractionPath(InteractionPath interactionPath, DiagnosticChain diagnostics, Map<Object, Object> context) {
//		return validate_EveryDefaultConstraint(interactionPath, diagnostics, context);
		boolean result = true;
		if (result || diagnostics != null) result &= validateInteractionPath_interactionPathVerification(interactionPath, diagnostics, context);
		return result;
	}
	
	/**
	 * Validates the orVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateInteractionPath_interactionPathVerification(InteractionPath interactionPath, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return interactionPath.interactionPathVerification(diagnostics, context);
	}
	

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateLifeline(Lifeline lifeline, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(lifeline, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		if (!validate_NoCircularContainment(termination, diagnostics, context)) return false;
//		boolean result = validate_EveryMultiplicityConforms(termination, diagnostics, context);
		boolean result = true;
//		if (result || diagnostics != null) result &= validate_EveryDataValueConforms(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryReferenceIsContained(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryBidirectionalReferenceIsPaired(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryProxyResolves(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_UniqueID(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryKeyUnique(termination, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryMapEntryUnique(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_terminationVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_orVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_cancelVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_exceptionTerminationVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_terminationFirstLevelVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_whileTerminationVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_untilTerminationVerification(termination, diagnostics, context);
		if (result || diagnostics != null) result &= validateTermination_multipleInstanceTerminationVerification(termination, diagnostics, context);
		return result;
	}

	/**
	 * Validates the terminationVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_terminationVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.terminationVerification(diagnostics, context);
	}

	/**
	 * Validates the orVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_orVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.orVerification(diagnostics, context);
	}

	/**
	 * Validates the cancelVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_cancelVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.cancelVerification(diagnostics, context);
	}

	/**
	 * Validates the exceptionTerminationVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_exceptionTerminationVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.exceptionTerminationVerification(diagnostics, context);
	}

	/**
	 * Validates the terminationFirstLevelVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_terminationFirstLevelVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.terminationFirstLevelVerification(diagnostics, context);
	}

	/**
	 * Validates the whileTerminationVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_whileTerminationVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.whileTerminationVerification(diagnostics, context);
	}

	/**
	 * Validates the untilTerminationVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_untilTerminationVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.untilTerminationVerification(diagnostics, context);
	}

	/**
	 * Validates the multipleInstanceTerminationVerification constraint of '<em>Termination</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTermination_multipleInstanceTerminationVerification(Termination termination, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return termination.multipleInstanceTerminationVerification(diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCondition(Condition condition, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(condition, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTimeExpresion(TimeExpresion timeExpresion, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(timeExpresion, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTimeConstraint(TimeConstraint timeConstraint, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(timeConstraint, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTimeObservation(TimeObservation timeObservation, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(timeObservation, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateProtocolReference(ProtocolReference protocolReference, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(protocolReference, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCorrelation(Correlation correlation, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(correlation, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateRole(Role role, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(role, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCFSSync(CFSSync cfsSync, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(cfsSync, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCFSNoSync(CFSNoSync cfsNoSync, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(cfsNoSync, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateAnd(And and, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(and, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateOr(Or or, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(or, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateXor(Xor xor, DiagnosticChain diagnostics, Map<Object, Object> context) {
		if (!validate_NoCircularContainment(xor, diagnostics, context)) return false;
//		boolean result = validate_EveryMultiplicityConforms(xor, diagnostics, context);
		boolean result = true;
//		if (result || diagnostics != null) result &= validate_EveryDataValueConforms(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryReferenceIsContained(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryBidirectionalReferenceIsPaired(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryProxyResolves(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_UniqueID(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryKeyUnique(xor, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryMapEntryUnique(xor, diagnostics, context);
		if (result || diagnostics != null) result &= validateXor_interactionPathTerminations(xor, diagnostics, context);
		return result;
	}

	/**
	 * Validates the interactionPathTerminations constraint of '<em>Xor</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateXor_interactionPathTerminations(Xor xor, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return xor.interactionPathTerminations(diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateIf(If if_, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(if_, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateLoop(Loop loop, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(loop, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateException(ar.edu.utn.frsf.cidisi.upcolbpip.interactionprotocols.Exception exception, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(exception, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCancel(Cancel cancel, DiagnosticChain diagnostics, Map<Object, Object> context) {
		if (!validate_NoCircularContainment(cancel, diagnostics, context)) return false;
//		boolean result = validate_EveryMultiplicityConforms(cancel, diagnostics, context);
		boolean result = true;
//		if (result || diagnostics != null) result &= validate_EveryDataValueConforms(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryReferenceIsContained(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryBidirectionalReferenceIsPaired(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryProxyResolves(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_UniqueID(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryKeyUnique(cancel, diagnostics, context);
//		if (result || diagnostics != null) result &= validate_EveryMapEntryUnique(cancel, diagnostics, context);
		if (result || diagnostics != null) result &= validateCancel_cancelAndVerification(cancel, diagnostics, context);
		if (result || diagnostics != null) result &= validateCancel_cancelOrVerification(cancel, diagnostics, context);
		return result;
	}

	/**
	 * Validates the cancelAndVerification constraint of '<em>Cancel</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCancel_cancelAndVerification(Cancel cancel, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return cancel.cancelAndVerification(diagnostics, context);
	}

	/**
	 * Validates the cancelOrVerification constraint of '<em>Cancel</em>'.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCancel_cancelOrVerification(Cancel cancel, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return cancel.cancelOrVerification(diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateMultipleInstance(MultipleInstance multipleInstance, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(multipleInstance, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTransaction(Transaction transaction, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(transaction, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateCompensation(Compensation compensation, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return validate_EveryDefaultConstraint(compensation, diagnostics, context);
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateTerminationElement(TerminationElement terminationElement, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return true;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateLoopType(LoopType loopType, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return true;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateMultipleInstancesType(MultipleInstancesType multipleInstancesType, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return true;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public boolean validateSynchronizationType(SynchronizationType synchronizationType, DiagnosticChain diagnostics, Map<Object, Object> context) {
		return true;
	}

	/**
	 * Returns the resource locator that will be used to fetch messages for this validator's diagnostics.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public ResourceLocator getResourceLocator() {
		// TODO
		// Specialize this to return a resource locator for messages specific to this validator.
		// Ensure that you remove @generated or mark it @generated NOT
		return super.getResourceLocator();
	}

} //InteractionprotocolsValidator
